package com.yl.model.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.yl.config.JsonLongSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

@Data
public class BaseVO implements Serializable {


    @ApiModelProperty("住建Id")
    @JsonSerialize(using = JsonLongSerializer.class)        //Long类型长度过长，导致精度丢失方案
    private Long id;

    @ApiModelProperty("创建时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;                //创建时间

    @ApiModelProperty("更新时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;                //更新时间


    @ApiModelProperty("是否删除")
    private Boolean isDel;

    //分页参数
    @ApiModelProperty("页码")
    private int current;            //页码


    @ApiModelProperty("每页展示条数")
    private int size;                //每页展示条数

    @ApiModelProperty("开始时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date startTime;        //开始时间yyyy-mm-dd


    @ApiModelProperty("截止时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date endTime;            //结束时间yyyy-mm-dd

}
